]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
bluetooth: Remove GnomeBluetoothApplet hacks
authorBastien Nocera <hadess@hadess.net>
Tue, 26 Nov 2013 14:08:18 +0000 (15:08 +0100)
committerBastien Nocera <hadess@hadess.net>
Tue, 26 Nov 2013 17:53:18 +0000 (18:53 +0100)
https://bugzilla.gnome.org/show_bug.cgi?id=719341

configure.ac
docs/reference/shell/Makefile.am
js/ui/status/bluetooth.js
src/Makefile.am
src/gnome-shell-plugin.c
src/main.c
src/run-js-test.c

index 97ee139d2b4d82614fb83f4691e1b56274563382..69187c24f501d824579391ecc379774f67331010 100644 (file)
@@ -140,19 +140,11 @@ AS_IF([test x$enable_browser_plugin = xyes], [
 ])
 AM_CONDITIONAL(BUILD_BROWSER_PLUGIN, test x$enable_browser_plugin = xyes)
 
-AC_MSG_CHECKING([for bluetooth support])
-PKG_CHECK_EXISTS([gnome-bluetooth-1.0 >= 3.9.0],
-        [BLUETOOTH_DIR=`$PKG_CONFIG --variable=applet_libdir gnome-bluetooth-1.0`
-        BLUETOOTH_LIBS=`$PKG_CONFIG --variable=applet_libs gnome-bluetooth-1.0`
-        AC_SUBST([BLUETOOTH_LIBS],["$BLUETOOTH_LIBS"])
-        AC_SUBST([BLUETOOTH_DIR],["$BLUETOOTH_DIR"])
-        AC_DEFINE_UNQUOTED([BLUETOOTH_DIR],["$BLUETOOTH_DIR"],[Path to installed GnomeBluetooth typelib and library])
-        AC_DEFINE([HAVE_BLUETOOTH],[1],[Define if you have libgnome-bluetooth-applet])
-        AC_SUBST([HAVE_BLUETOOTH],[1])
-        AC_MSG_RESULT([yes])],
+PKG_CHECK_MODULES(BLUETOOTH, gnome-bluetooth-1.0 >= 3.9.0,
+        [AC_DEFINE([HAVE_BLUETOOTH],[1],[Define if you have libgnome-bluetooth-applet])
+        AC_SUBST([HAVE_BLUETOOTH],[1])],
        [AC_DEFINE([HAVE_BLUETOOTH],[0])
-        AC_SUBST([HAVE_BLUETOOTH],[0])
-        AC_MSG_RESULT([no])])
+        AC_SUBST([HAVE_BLUETOOTH],[0])])
 
 PKG_CHECK_MODULES(CALENDAR_SERVER, libecal-1.2 >= $LIBECAL_MIN_VERSION libedataserver-1.2 >= $LIBEDATASERVER_MIN_VERSION gio-2.0)
 AC_SUBST(CALENDAR_SERVER_CFLAGS)
index 588e72b9c08959ddefb00240c6b6ab0adedc23f3..c4b064fcb2f02ef20c3589bcfcf3f2095afa7a13 100644 (file)
@@ -112,7 +112,7 @@ expand_content_files=
 # e.g. GTKDOC_CFLAGS=-I$(top_srcdir) -I$(top_builddir) $(GTK_DEBUG_FLAGS)
 # e.g. GTKDOC_LIBS=$(top_builddir)/gtk/$(gtktargetlib)
 GTKDOC_CFLAGS=$(GNOME_SHELL_CFLAGS)
-GTKDOC_LIBS=$(GNOME_SHELL_LIBS) $(BLUETOOTH_LIBS) $(top_builddir)/src/libgnome-shell-menu.la $(top_builddir)/src/libgnome-shell-base.la $(top_builddir)/src/libgnome-shell.la
+GTKDOC_LIBS=$(GNOME_SHELL_LIBS) $(top_builddir)/src/libgnome-shell-menu.la $(top_builddir)/src/libgnome-shell-base.la $(top_builddir)/src/libgnome-shell.la
 
 # This includes the standard gtk-doc make rules, copied by gtkdocize.
 include $(top_srcdir)/gtk-doc.make
index 47171c7ff1aa51305c1cce95edd2cf5953ad62e0..75ab8e316d2c1d536d263ed92a663dddeceef326 100644 (file)
@@ -3,7 +3,6 @@
 const Clutter = imports.gi.Clutter;
 const GLib = imports.gi.GLib;
 const Gio = imports.gi.Gio;
-const GnomeBluetoothApplet = imports.gi.GnomeBluetoothApplet;
 const GnomeBluetooth = imports.gi.GnomeBluetooth;
 const Lang = imports.lang;
 const St = imports.gi.St;
index bacc0ee205009b1439d38b76ce65102950f0df65..1c0d377e499464b1fdd9261c1f096125ad31cdb4 100644 (file)
@@ -191,7 +191,7 @@ gnome_shell_CPPFLAGS = \
 
 # Here, and after, we repeat mutter and bluetooth libraries just for the rpath
 # The dependency is already pulled in by libtool
-gnome_shell_LDADD = libgnome-shell.la libgnome-shell-js.la $(GNOME_SHELL_LIBS) $(MUTTER_LIBS) $(BLUETOOTH_LIBS)
+gnome_shell_LDADD = libgnome-shell.la libgnome-shell-js.la $(GNOME_SHELL_LIBS) $(MUTTER_LIBS)
 gnome_shell_DEPENDENCIES = libgnome-shell.la
 
 if HAVE_MUTTER_WAYLAND
@@ -205,7 +205,7 @@ gnome_shell_wayland_CPPFLAGS = \
        $(MUTTER_WAYLAND_CFLAGS) \
        $(gnome_shell_cflags)
 
-gnome_shell_wayland_LDADD = libgnome-shell-wayland.la libgnome-shell-js.la $(GNOME_SHELL_LIBS) $(MUTTER_WAYLAND_LIBS) $(BLUETOOTH_LIBS)
+gnome_shell_wayland_LDADD = libgnome-shell-wayland.la libgnome-shell-js.la $(GNOME_SHELL_LIBS) $(MUTTER_WAYLAND_LIBS)
 gnome_shell_wayland_DEPENDENCIES = libgnome-shell-wayland.la
 endif HAVE_MUTTER_WAYLAND
 
@@ -259,7 +259,7 @@ gnome_shell_perf_helper_LDADD = $(SHELL_PERF_HELPER_LIBS)
 noinst_PROGRAMS += run-js-test
 
 run_js_test_CPPFLAGS = $(MUTTER_CFLAGS) $(gnome_shell_cflags)
-run_js_test_LDADD = libgnome-shell.la $(GNOME_SHELL_JS_LIBS) $(MUTTER_LIBS) $(BLUETOOTH_LIBS)
+run_js_test_LDADD = libgnome-shell.la $(GNOME_SHELL_JS_LIBS) $(MUTTER_LIBS)
 run_js_test_LDFLAGS = -export-dynamic
 
 run_js_test_SOURCES =                  \
@@ -331,8 +331,7 @@ ShellMenu_0_1_gir_FILES = \
        gtkmenutrackeritem.h            \
        $(NULL)
 ShellMenu_0_1_gir_SCANNERFLAGS =       \
-       --namespace=ShellMenu --identifier-prefix=Gtk \
-       $(if $(BLUETOOTH_DIR),-L $(BLUETOOTH_DIR),)
+       --namespace=ShellMenu --identifier-prefix=Gtk
 INTROSPECTION_GIRS += ShellMenu-0.1.gir
 CLEANFILES += ShellMenu-0.1.gir
 
@@ -348,7 +347,7 @@ Shell_0_1_gir_FILES = $(libgnome_shell_la_gir_sources)
 Shell_0_1_gir_SCANNERFLAGS =   \
        --include-uninstalled=$(builddir)/St-1.0.gir \
        --include-uninstalled=$(builddir)/ShellMenu-0.1.gir \
-       --add-include-path=$(MUTTER_GIR_DIR) $(if $(BLUETOOTH_DIR),-L $(BLUETOOTH_DIR),)
+       --add-include-path=$(MUTTER_GIR_DIR)
 INTROSPECTION_GIRS += Shell-0.1.gir
 CLEANFILES += Shell-0.1.gir
 
index 0c41c0053fab96746849431ae1d6419eea085234..e4a3072ca1fdda25fe7b95b1e7ecb986270d195a 100644 (file)
@@ -384,17 +384,3 @@ MetaPluginInfo *gnome_shell_plugin_plugin_info (MetaPlugin *plugin)
 
   return &info;
 }
-
-#if HAVE_BLUETOOTH
-/* HACK:
-   Add a non-static function that calls into libgnome-bluetooth-applet.so,
-   to avoid the linker being too smart and removing the dependency.
-   This function is never actually called.
-*/
-extern GType bluetooth_applet_get_type(void);
-void _shell_link_to_bluetooth(void);
-
-void _shell_link_to_bluetooth(void) {
-  bluetooth_applet_get_type();
-}
-#endif
index c3ff6111e5715c964b479c26e924a2e2329e0be6..79161b63e667fc274e8a20247de238f73cf534dd 100644 (file)
@@ -173,10 +173,6 @@ shell_introspection_init (void)
 
   g_irepository_prepend_search_path (MUTTER_TYPELIB_DIR);
   g_irepository_prepend_search_path (GNOME_SHELL_PKGLIBDIR);
-#if HAVE_BLUETOOTH
-  g_irepository_prepend_search_path (BLUETOOTH_DIR);
-#endif
-
 }
 
 static void
index 84c1d26d251fee12abad268121d0476239851d4a..b81f6d215e752e8d8e041f5317dc4743c6f43a57 100644 (file)
@@ -126,14 +126,6 @@ main(int argc, char **argv)
   g_set_prgname (title);
   g_free (title);
 
-#if HAVE_BLUETOOTH
-  /* The module imports are all so intertwined that if the test
-   * imports anything in js/ui, it will probably eventually end up
-   * pulling in ui/status/bluetooth.js. So we need this.
-   */
-  g_irepository_prepend_search_path (BLUETOOTH_DIR);
-#endif
-
   /* evaluate the script */
   error = NULL;
   if (!gjs_context_eval (js_context, script, len,